<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2020/12/10
  Time: 12:24
  To change this template use File | Settings | File Templates.
--%>

<%--使用标准标签库中的<c:foreach>标签、<c:if>标签和<c:out>标签列出1-100中能被2整除不能被3整除的数字。--%>

<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>列出1-100中能被2整除不能被3整除的数字</title>
</head>
<b>
<body>
<font size="6">

<c:out value="1-100中能被2整除不能被3整除的数字:"/>
<br>
<c:forEach var="item" begin="1" end="100" step="1">
    <c:if test="${item%2 == 0 && item%3 != 0}" var="condition">
        <c:out value="${item}   "></c:out>
    </c:if>
</c:forEach>


</font>
</body>
</b>
</html>
